package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.PaperSubjectMapper;
import com.ruoyi.system.domain.PaperSubject;
import com.ruoyi.system.service.IPaperSubjectService;

/**
 * 试卷考题表Service业务层处理
 *
 * @author ruoyi
 * @date 2022-11-20
 */
@Service
public class PaperSubjectServiceImpl implements IPaperSubjectService
{
    @Autowired
    private PaperSubjectMapper paperSubjectMapper;

    /**
     * 查询试卷考题表
     *
     * @param paperId 试卷考题表主键
     * @return 试卷考题表
     */
    @Override
    public List<PaperSubject> selectPaperSubjectByPaperId(Long paperId)
    {
        return paperSubjectMapper.selectPaperSubjectByPaperId(paperId);
    }

    /**
     * 查询试卷考题表列表
     *
     * @param paperSubject 试卷考题表
     * @return 试卷考题表
     */
    @Override
    public List<PaperSubject> selectPaperSubjectList(PaperSubject paperSubject)
    {
        return paperSubjectMapper.selectPaperSubjectList(paperSubject);
    }

    /**
     * 新增试卷考题表
     *
     * @param paperSubject 试卷考题表
     * @return 结果
     */
    @Override
    public int insertPaperSubject(PaperSubject paperSubject)
    {
        return paperSubjectMapper.insertPaperSubject(paperSubject);
    }

    /**
     * 修改试卷考题表
     *
     * @param paperSubject 试卷考题表
     * @return 结果
     */
    @Override
    public int updatePaperSubject(PaperSubject paperSubject)
    {
        return paperSubjectMapper.updatePaperSubject(paperSubject);
    }

    /**
     * 批量删除试卷考题表
     *
     * @param paperIds 需要删除的试卷考题表主键
     * @return 结果
     */
    @Override
    public int deletePaperSubjectByPaperIds(Long[] paperIds)
    {
        return paperSubjectMapper.deletePaperSubjectByPaperIds(paperIds);
    }

    /**
     * 删除试卷考题表信息
     *
     * @param paperId 试卷考题表主键
     * @return 结果
     */
    @Override
    public int deletePaperSubjectByPaperId(Long paperId)
    {
        return paperSubjectMapper.deletePaperSubjectByPaperId(paperId);
    }
}
